<script setup>
    import axios from 'axios';
    import { onMounted } from 'vue';
    import { ref } from 'vue'

    const tableData = ref([])
    onMounted(() => {
        axios.get('/log/list').then(res => {
            tableData.value = res.data.data
        })
    })
</script>

<template>
    <h2>系统日志</h2>

    <el-table :data="tableData" stripe style="width: 100%">
    <el-table-column prop="index" label="序号" width="80" />
    <el-table-column prop="name" label="操作用户" width="120" />
    <el-table-column prop="ip" label="IP地址" width="130" />
    <el-table-column prop="requesUrl" label="请求URL" width="280" />
    <el-table-column prop="beginTime" label="请求时间" width="200" />
    <el-table-column prop="requestMethod" label="请求方法" width="100" />
    <el-table-column prop="costTime" label="花费时长" width="110" />
  </el-table>

</template>

<style scoped>

</style>